#include<stdio.h>
int main ()
{
	double u,v,w,l;
	int t;
	scanf("%d",&t);
	while(t--)
	{
		scanf("%lf %lf %lf %lf",&u,&v,&w,&l);
		printf("%.3f\n",(l*w)/(u+v));
	}
	return 0;
}
